package com.filldream.fastboot.common.entity;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import java.util.List;

/**
 * @url https://open.dingtalk.com/document/orgapp/custom-robot-access
 */
@Accessors(chain = true)
@Data
public class SendDdRobotSTO {

    @ApiModelProperty(value = "消息类型 text markdown image news")
    private String msgtype;

    private At at;

    private Text text;

    private Link link;

    private Markdown markdown;

    @Data
    @Accessors(chain = true)
    public static class At{
        private List<String> atMobiles;
        private List<String> atUserIds;
        private Boolean isAtAll;
    }

    @Data
    @Accessors(chain = true)
    public static class Text{
        private String content;
    }

    @Data
    @Accessors(chain = true)
    public static class Link{
        private String text;
        private String title;
        private String picUrl;
        private String messageUrl;
    }

    @Data
    @Accessors(chain = true)
    public static class Markdown{
        private String text;
        private String title;
    }


}
